package com.sy.service.impl;
import com.sy.exception.BusinessException;
import com.sy.mapper.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.stereotype.Service;

@Service
public abstract class BaseServiceImpl {

    @Autowired
    protected UserMapper userMapper;
    @Autowired
    protected ProvinceMapper provinceMapper;
    @Autowired
    protected VideoMapper videoMapper;
    @Autowired
    protected ThumbsUpMapper thumbsUpMapper;
    @Autowired
    protected MockExamMapper mockExamMapper;
    @Autowired
    protected DriSchoolMapper driSchoolMapper;
    @Autowired
    protected PriceRegionMapper priceRegionMapper;
    @Autowired
    protected DriClassMapper driClassMapper;
    @Autowired
    protected CommitMapper commitMapper;
    @Autowired
    protected ServeMapper serveMapper;
    @Autowired
    protected CarDistributionMapper carDistributionMapper;
    @Autowired
    protected TrainerMapper trainerMapper;
    @Autowired
    protected AdminMapper adminMapper;
    @Autowired
    protected ArticleMapper articleMapper;
    @Autowired
    protected TechTimeMapper techTimeMapper;
    @Autowired
    protected PartnerMapper partnerMapper;

    protected void buildError(HttpStatus httpStatus, String errMsg) {
        throw new BusinessException(httpStatus, errMsg);
    }
}
